package com.zm.demo.core.leetcode;

import java.util.Map;

public class strStr {
    public int strStr(String haystack, String needle) {
        if (haystack == null){
            return -1;
        }
        if (needle == null){
            return -1;
        }

        if(needle.equals("")){
            return 0;
        }
        return haystack.indexOf(needle);
    }
}